# Embed a font
ADDFONT="stilltim.ttf,Stilltime">>

##### Set up a form to use as the background
PAGE=8.5,11 NEWFORM=backgrd>>

# Use whole page and divide into 80 units in X direction and 50 in Y direction
BOX=0,0,8.5,11,80,50>>
LINEW=2>>
LINE=1,3,79,3>>
LINE=1,47,79,47>>
LINEW=.1>>

# Set the report title
FONT=15,32 COMP=120>>
ALIGN=C X=40 Y=2>>Sample Report

# Set the report footer
FONT=2,9 COMP=100>>
ALIGN=L X=3 Y=48>><SUP>*</SUP>Here is a sample report footer.

##### End of main background 

##### Set up a form to use as the background for the tables

PAGE=8.5,11 NEWFORM=showtbl>>

# Set up the table and headings
FONT=5,12>>
TBLROWCOLOR=1,.9,1,.9>>
TBL=10,30,18,1,20,60,79>>
TBLROWALIGN=1,C,C,C>>
TBLROW=1>>
TBLDATA2>>Store #|City/State|Purchases YTD
TBLALIGN=L,L,R>>
OFFSET=.5,.1>>

# Draw a purble box for the total
FCOLOR=.6,.6,.95 SCOLOR=.6,.6,.95>>
RECTF=40,30,79,31.25>>
FCOLOR=1,1,1 SCOLOR=1,1,1>>
FONT=5,18>>
X=50 Y=31>>TOTAL
FCOLOR=0,0,0 SCOLOR=0,0,0 COMP=100>>

##### End of table background

# Report Page
PAGE=8.5,11 USEFORM=backgrd USEFORM=showtbl>>
OUTLINE='1,ABC Company'>>
BOX=0,0,8.5,11,80,50>>
FONT=2,15 ALIGN=L>>
X=1 Y=6>>ABC Company
Y=+>>123 Main Street
Y=+>>Anytown, USA
FONT=2,12>>

TBLROW=2>>
TBLDATA2>>1000|Detroit, MI|$15,000
TBLDATA2>>1020|Canton, OH|$2,500
TBLDATA2>>1050|Lima, OH|$100,000

ALIGN=R FONT=5,18 FCOLOR=1,1,1 SCOLOR=1,1,1>>
X=78.5 Y=31>>$117,500
FCOLOR=0,0,0 SCOLOR=0,0,0>>

# Report Page
PAGE=8.5,11 USEFORM=backgrd USEFORM=showtbl>>
OUTLINE='1,Best Company'>>
BOX=0,0,8.5,11,80,50>>
FONT=2,15 ALIGN=L>>
X=1 Y=6>>Best Company
Y=+>>555 Main Street
Y=+>>Someplace, USA
FONT=2,12>>

TBLROW=2>>
TBLDATA2>>A-1508|Tampa, FL|$35,000
TBLDATA2>>B-9988|Dallas, TX|$50,000
TBLDATA2>>A-8876|Las Vegas, NV|$100,000
TBLDATA2>>M-8873|Mexico City, Mexico|$60,000
TBLDATA2>>T-2761|Los Angeles, CA|$75,000

ALIGN=R FONT=5,18 FCOLOR=1,1,1 SCOLOR=1,1,1>>
X=78.5 Y=31>>$320,000
FCOLOR=0,0,0 SCOLOR=0,0,0>>

# Report Page
PAGE=8.5,11 USEFORM=backgrd USEFORM=showtbl>>
OUTLINE='1,Mega Company'>>
BOX=0,0,8.5,11,80,50>>
FONT=2,15 ALIGN=L>>
X=1 Y=6>>Mega Company
Y=+>>900 1st Street
Y=+>>Smalltown, USA
FONT=2,12>>

TBLROW=2>>
TBLDATA2>>O-59283|Toronto, ON|$55,000
TBLDATA2>>F-87672|Paris, France|$45,000
TBLDATA2>>GB-98716|Lodon, Great Britain|$50,000
TBLDATA2>>D-15723|Munich, Germany|$105,000
TBLDATA2>>J-00978|Tokyo, Japan|$75,000

ALIGN=R FONT=5,18 FCOLOR=1,1,1 SCOLOR=1,1,1>>
X=78.5 Y=31>>$330,000
FCOLOR=0,0,0 SCOLOR=0,0,0>>

# Report Page
PAGE=8.5,11 USEFORM=backgrd>>
OUTLINE='1,Summary'>>
BOX=0,0,8.5,11,80,50>>
FONT=2,15 ALIGN=L>>
X=1 Y=6>>Report Summary
FONT=2,12>>

TBLCOLCOLOR=1,1,.8,.8>>
TBLROWCOLOR=1,1,1,.8>>
TBLCELLCOLOR=1,5,.8,1,.8>>
TBL=10,16,5,20,50,60>>
TBLROW=1>>
TBLCOLALIGN=1,L>>
TBLROWALIGN=1,C,C>>
TBLALIGN=L,R>>
TBLDATA2>><FONT=5,11>Company|Sales
TBLDATA2>><FONT=5,11>ABC Company<FONT=2,11>|117,500
TBLDATA2>><FONT=5,11>Best Company<FONT=2,11>|320,000
TBLDATA2>><FONT=5,11>Mega Company<FONT=2,11>|330,000
TBLDATA2>><FONT=5,11>Total<FONT=2,11>|$767,500
